<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" href="../../style/common.css" />
<title>保健所検索</title>
<script type="text/javascript">
	function onLoad() {
		window.android.doGetHoKenJoAreaList();
	}

	function setTable() {
		var jouhou = window.android.getHoKenJoList();
		var total = jouhou.size();
		var x = document.getElementById("jouhoutable");
		for ( var j = x.rows.length - 1; j >= 0; j--) {
			x.deleteRow(j);
		}
		for ( var i = 0; i < total; i++) {
			var x1 = x.insertRow(i);
			var y1 = x1.insertCell(0);
			var newTable = document.createElement('table');
			newTable.border = 1;
			newTable.width = "100%";
			newTable.style.borderCollapse = "collapse";
			newTable.style.border = "none";
			newTable.style.fontSize = "14px";
			y1.appendChild(newTable);
			var tr1 = newTable.insertRow(0);
			var td11 = tr1.insertCell(0);
			td11.innerHTML = jouhou.get(i).getSite();
			td11.colSpan = 2;
			var tr2 = newTable.insertRow(1);
			var td21 = tr2.insertCell(0);
			td21.width = "30%";
			td21.align = "center";
			var td22 = tr2.insertCell(1);
			td21.innerHTML = jouhou.get(i).getZipCode();
			td22.innerHTML = jouhou.get(i).getAddress();
			var tr3 = newTable.insertRow(2);
			var td31 = tr3.insertCell(0);
			td31.innerHTML = "電話 " + jouhou.get(i).getTelephone()
					+ "<br />FAX " + jouhou.get(i).getFaxNo()
			td31.colSpan = 2;
		}
		window.android.stopProgressBar();
	}

	function setArea() {
		var areaList = document.getElementById("areaSelect");
		var jouhou = window.android.getHoKenJoAreaList();
		if (null == jouhou || jouhou.size() == 0) {
			areaList.disabled = true;
		} else {
			areaList.options.add(new Option("", ""));
			for ( var i = 0; i < jouhou.size(); i++) {
				areaList.options.add(new Option(jouhou.get(i), jouhou.get(i)));
			}
		}
		window.android.stopProgressBar();
	}

	function changed() {
		var areaList = document.getElementById("areaSelect");
		var curstr = areaList.value;
		window.android.doGetHoKenJoList(curstr);
	}
</script>
</head>

<body onload="onLoad()">
	<table width="100%" border="0">
		<tr>
			<td><b>保健所検索</b>
				<hr class="title_divison work_theme_background_color" /></td>
		</tr>
		<tr>
			<td>こちらから保健所を検索できます。</td>
		</tr>
		<tr>
			<td><p>都道府県を選択してください</p> <select id="areaSelect"
				onchange="changed()"></select></td>
		</tr>
		<tr>
			<td><br />
				<table width="100%" id="jouhoutable">
				</table></td>
		</tr>
		<tr>
			<td><br />
				<table width="100%" border="0">
					<tr>
						<td align="left">
							<div class="back_button"
								onclick="location.href='S1-0111-5-5-3.html';">&lt;&nbsp;もどる</div>
						</td>
					</tr>
				</table></td>
		</tr>
	</table>
</body>
</html>
